<?php
$id = isset($this->id) ? 'id="' . $this->id . '" ' : null;
$class = isset($this->class) ? 'class="' . $this->class . '" ' : null;

if($this->homeLink) {
    $homeLink = '<li class="home"><a href="/">' . $this->homeLink . '</a></li>';
} else {
    $homeLink = null;
}
if($this->menuData) {
    echo '<ul ' . $id . $class . '>' . $homeLink . $this->partialLoop('menu/_item.phtml', 'digNavigation', $this->menuData) . '</ul>';
}